package com.example.boot.controller;

import lombok.extern.log4j.Log4j2;
import org.springframework.http.HttpStatus;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;

/**
 * 模板访问路由 ModelAndView
 */
@Controller
public class InfoController {
    @RequestMapping(value = "info/test1", method = RequestMethod.GET)
    @ResponseBody
    public String test1() {
        //ModelAndView
        return "info";
    }

    @GetMapping("/info/")
    public String hiinfo() {
        return "info index";
    }
}
